package IC.Symbols;

public enum Kind {
	Variable("Variable", 0x1 | 0x2 | 0x4 | 0x8 | 0x10 ),
	ReturnVariable("Return Variable", 0x2 ),
	Field("Field", 0x1 | 0x4 | 0x8 | 0x10),
	StaticMethod("Static Method", 0x2 | 0x4 | 0x8 | 0x10 ),
	VirtualMethod("Virtual Method", 0x8 | 0x4 | 0x8 | 0x10 ),
	Parameter("Parameter", 0x1 | 0x2 | 0x4 | 0x8 | 0x10 ),
	Class("Class", 0x2 | 0x10 ),
	This("This", 0x8 );
	
	private final String kindId;
	private final int kindParams;
	
    private Kind(String id, int params)
    {
        kindId = id;
        this.kindParams = params;
    }

    public String toString()
    {
        return kindId;
    }
       
    public boolean FindAsLocation(){
    	return (kindParams & 0x1) != 0;
    }
    
    public boolean FindInStaticSemantic(){
    	return (kindParams & 0x2) != 0;
    }
    
    public boolean IncludeInSymbolsPrint(){
    	return (kindParams & 0x4) != 0;
    }
    
    public boolean PrintableTypeName(){
    	return (kindParams & 0x8) != 0;
    }
    
    public boolean PrintableSymbolName(){
    	return (kindParams & 0x10) != 0;
    }
    
	public int getParams(){
    	return kindParams;
    }
}
